//  Copyright (c) Microsoft Corporation.  All Rights Reserved.

using System;
using System.Collections.Generic;
using System.Text;

namespace EAI.Common
{
    public static class Constants
    {
        public const string RequestSecurityTokenAction = "http://schemas.xmlsoap.org/ws/2005/02/trust/RST/Issue";
        public const string RequestSecurityTokenResponseAction = "http://schemas.xmlsoap.org/ws/2005/02/trust/RSTR/Issue";
        public const string TrustNamespace = "http://schemas.xmlsoap.org/ws/2005/02/trust";
    }

    public static class WSTrust
    {
        public const string Prefix = "wst";
        public const string Namespace = "http://schemas.xmlsoap.org/ws/2005/02/trust";
        public const string RequestSecurityToken = "RequestSecurityToken";
        public const string RequestType = "RequestType";
        public const string RequestTypeIssue = "http://schemas.xmlsoap.org/ws/2005/02/security/trust/Issue";
        public const string TokenType = "TokenType";
        public const string Context = "Context";
        public const string KeyType = "KeyType";
        public const string KeySize = "KeySize";
        public const string RenewTarget = "RenewTarget";
        public const string CloseTarget = "CancelTarget";
        public const string AppliesTo = "AppliesTo";
        public const string BinarySecret = "BinarySecret";
        public const string NonceType = "http://schemas.xmlsoap.org/ws/2005/02/trust/Nonce";
        public static readonly Uri KeyTypeSymmetric = new Uri("http://schemas.xmlsoap.org/ws/2005/02/trust/SymmetricKey");
        public static readonly Uri KeyTypeAsymmetric = new Uri("http://schemas.xmlsoap.org/ws/2005/02/trust/PublicKey");
        public const string RequestedSecurityToken = "RequestedSecurityToken";
        public const string RequestedProofToken = "RequestedProofToken";
        public const string RequestSecurityTokenResponse = "RequestSecurityTokenResponse";
        public const string Lifetime = "Lifetime";
        public const string RequestedAttachedReference = "RequestedAttachedReference";
        public const string RequestedUnattachedReference = "RequestedUnattachedReference";
        public const string Entropy = "Entropy";
        public const string ComputedKey = "ComputedKey";
        public const string Psha1ComputedKeyUri = "http://schemas.xmlsoap.org/ws/2005/02/trust/CK/PSHA1";
        public const string RequestedTokenClosed = "RequestedTokenCancelled";
    }

    public static class WSPolicy
    {
        public const string Prefix = "wsp";
        public const string Namespace = "http://schemas.xmlsoap.org/ws/2004/09/policy";
    }

    public static class WSUtility
    {
        public const string Prefix = "wsu";
        public const string Namespace = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
        public const string Created = "Created";
        public const string Expires = "Expires";

        internal static readonly string[] AcceptedDateTimeFormats = new string[]
        {
            "yyyy-MM-ddTHH:mm:ss.fffffffZ",
            "yyyy-MM-ddTHH:mm:ss.ffffffZ",
            "yyyy-MM-ddTHH:mm:ss.fffffZ",
            "yyyy-MM-ddTHH:mm:ss.ffffZ",
            "yyyy-MM-ddTHH:mm:ss.fffZ",
            "yyyy-MM-ddTHH:mm:ss.ffZ",
            "yyyy-MM-ddTHH:mm:ss.fZ",
            "yyyy-MM-ddTHH:mm:ssZ"
        };

    }

}
